

export default class Controller {
    constructor (CommonService, $state) {
        "ngInject"
        this.service = CommonService;
        this.state = $state;
        this.data  = {
            username: 'ctg-perm',
            password: '111111'
        };
        this.param =  {
            method: 'POST',
            url: '/login',
            data: this.data
        }
    }
    entry () {
        this.service.request(this.param).then((r) => {
            this.state.go('grant')
        })
    }
}